import pyperclip


def rename(inputStr):
    newStr = inputStr.replace('_', '')
    print(newStr)
    # 要复制到剪切板的字符串
    string_to_copy = newStr

    # 将字符串复制到剪切板
    pyperclip.copy(string_to_copy)

def doWork():
    inputStr = input("请输入字符串：")
    rename(inputStr)
    input("已复制到剪切板，按任意键退出")


if __name__ == '__main__':
    doWork()